<!DOCTYPE html>
<html>
<head>
    <title>样本建筑能耗数据采集表</title>
		<#include "/header.html">
</head>
<body>
<div id="rrapp" v-cloak>
    <div v-show="showList">
        <div class="grid-btn">
            <div class="form-group col-sm-2">
                <input type="text" class="form-control" v-model="q.name" @keyup.enter="query" placeholder="字典名称">
            </div>
			<#if shiro.hasPermission("testdemo:b87power:save")>
            <a class="btn btn-primary" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</a>
			</#if>
			<#if shiro.hasPermission("testdemo:b87power:update")>
            <a class="btn btn-primary" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</a>
			</#if>
			<#if shiro.hasPermission("testdemo:b87power:delete")>
            <a class="btn btn-primary" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
			</#if>
        </div>
        <table id="jqGrid"></table>
        <div id="jqGridPager"></div>
    </div>

    <div v-show="!showList" class="panel panel-default">
        <div class="panel-heading">{{title}}</div>
        <form class="form-horizontal">
														                    <div class="form-group">
                        <div class="col-sm-2 control-label">年份</div>
                        <div class="col-sm-10">
                            <input type="text" name="year" id="year" class="form-control" v-model="b87Power.year" placeholder=""/>
                        </div>
                    </div>
											                    <div class="form-group">
                        <div class="col-sm-2 control-label">市辖区用电总量</div>
                        <div class="col-sm-10">
                            <input type="text" name="powerAmount" id="powerAmount" class="form-control" v-model="b87Power.powerAmount" placeholder="市辖区用电总量"/>
                        </div>
                    </div>
											                    <div class="form-group">
                        <div class="col-sm-2 control-label">市辖区常住人口总数</div>
                        <div class="col-sm-10">
                            <input type="text" name="population" id="population" class="form-control" v-model="b87Power.population" placeholder="市辖区常住人口总数"/>
                        </div>
                    </div>
											                    <div class="form-group">
                        <div class="col-sm-2 control-label">人均用电量</div>
                        <div class="col-sm-10">
                            <input type="text" name="averagePower" id="averagePower" class="form-control" v-model="b87Power.averagePower" placeholder="人均用电量"/>
                        </div>
                    </div>
											                    <div class="form-group">
                        <div class="col-sm-2 control-label">文件路径</div>
                        <div class="col-sm-10">
                            <input type="text" name="filepath" id="filepath" class="form-control" v-model="b87Power.filepath" placeholder="文件路径"/>
                        </div>
                    </div>

							            <div class="form-group">
                <div class="col-sm-2 control-label">数据文件上传，原始数据文件类型为pdf,.xls,.xlsx,.docx,.doc</div>
                <div class="col-sm-10">
                    <input type="file" name="file" id="form_file" multiple="multiple" accept=".pdf,.xls,.xlsx,.docx,.doc" class="form-control"
                           placeholder="原始数据文件类型为pdf,.xls,.xlsx,.docx,.doc"/>
                    <input type="text" id="form_file_text" class="form-control" style="display :none" v-model="b87Power.filepath" placeholder="原始数据文件"/>
                </div>

            </div>

            <div class="form-group" v-if="flag">
                <div class="col-sm-2 control-label">已上传文件</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" name="uploadfilename"  id="uploadfilename"  v-model="b87Power.filepath" placeholder=""/>
                </div>
            </div>

            <div class="form-group">
                <div class="col-sm-2 control-label"></div>
                <input type="button" class="btn btn-primary" id="btnSaveOrUpdate" data-loading-text="保存中..." @click="saveOrUpdate" value="确定"/>
                &nbsp;&nbsp;<input type="button" class="btn btn-warning" @click="reload" value="返回"/>
                &nbsp;&nbsp;<input type="button" class="btn btn-primary" id="validateBtn" value="手动验证"></input>
                &nbsp;&nbsp;<input type="button" class="btn btn-primary" id="resetBtn" value="重置"></input>
            </div>
        </form>
    </div>
</div>

<script src="${request.contextPath}/statics/libs/bootstrapValidator.min.js"></script>
<script src="${request.contextPath}/statics/libs/zh_CN.js"></script>
<script src="${request.contextPath}/statics/libs/fileinput.min.js"></script>
<script src="${request.contextPath}/statics/libs/zh.js"></script>
<script src="${request.contextPath}/statics/js/modules/testdemo/b87power.js?_${.now?long}"></script>
</body>
</html>